home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1996 #15 / Monster Media Number 15 (Monster Media)(July 1996).ISO / math / alged34.zip / ALGEDENG.HLP < prev    next >
Text File  |  1996-06-06  |  17KB  |  351 lines

  1.                    Help text for the Algebra Editor
  2.  
  3. Copyright (c) 1994,1996 John Henckel
  4. Permission to use, copy, modify, distribute and sell this software
  5. and its documentation for any purpose is hereby granted without fee,
  6. provided that the above copyright notice appear in all copies and
  7. that both that copyright notice and this permission notice appear
  8. in supporting documentation.  All programs contained herein are provided
  9. to you "as is".  The implied warranties of merchantability and fitness
  10. for a particular purpose are expressly disclaimed.
  11.  
  12.      ╔═════════════╗
  13.      ║ QUICK START ║
  14.      ╚═════════════╝
  15.  
  16. To load the sample data file:
  17.  
  18.         1. Click "Load" in the upper right corner (or press 'l').
  19.         2. Type "alged" and press Enter.
  20.  
  21. Play with the sample data file and if you have any trouble, print the
  22. short tutorial in the alged.doc file.
  23.  
  24. (Press Esc to return, or press any key for more help...)
  25. ----------------------------------------------------------------------------
  26.  
  27. My name is John Henckel (internet: henckel@vnet.ibm.com).  I am a computer
  28. hobbyist;  I like to write computer programs to amuse myself, and this is one
  29. of them.  I also recommend my 2D collision simulator "Impact" found in
  30. http://www.coast.net/SimTel/msdos/simulatn.html.  Thanks to my family for
  31. letting me work on this.  Thanks to my manager at IBM in Rochester, Minnesota
  32. for permitting me to offer this program for free to the public.
  33.  
  34. Alged is a program for solving algebra problems.  There are other programs
  35. that can do symbolic formula manipulations, such as MathCad and Mathematica.
  36. The advantages of Alged are that it is
  37.     * Free!  The source code is also free!
  38.     * Light weight (it runs on a PC/XT with 256K of memory)
  39.     * Easy to use, ideal for education
  40.     * Fast and flexible 2D and 3D graphics
  41.     * Can be customized and translated (Flemish and French included).
  42. Of course, there are limitations.  Alged is by no means a "commercial grade"
  43. product (though I've seen worse!)  Alged does not handle matrices, series,
  44. integrals, derivatives, or transcendental transformations.  Imaginary numbers
  45. are supported only with the five basic operators (add, subt, mult, div, exp).
  46. Alged is a tool for symbolic math, so I have purposely avoided the "number
  47. crunching" algorithms.
  48.  
  49. ----------------------------------------------------------------------------
  50. Input Instructions:
  51.  
  52. The Alged screen has a menu at the top and a work area at the bottom.  At the
  53. lower left is the time of day and the percentage of heap memory used.  (When
  54. the heap reaches 100% Alged will exit.)  You manipulate the formulas in the
  55. work area by clicking on parts of them and then clicking on the menu.  You
  56. click the left mouse button in the work area to select the current expression
  57. or the PICK.  The pick is highlighted.  You click the right mouse button in
  58. the work area to select the KEY expression.  The key is copied to the bottom
  59. of the screen.  Notice that it is legal to click on the key, so the pick may
  60. be a subset of the key.  To scroll the work area, you can click on the border.
  61.  
  62. If your computer does not have a mouse, (or you just don't like to use it)
  63. you can use the [pageup], [pagedown] and [end] keys to select the pick.
  64. These keys descend the binary tree stored in memory.  You can copy the pick to
  65. the key by pressing '.'.  You can type the key by pressing 'k'.  You can copy
  66. the key to the work area by pressing [Insert].  You can delete the key by
  67. pressing [Enter].  To scroll the work area, you can use the arrow keys.
  68.  
  69. Some of the operations on the menu only use the pick, and some use both the
  70. pick and the key.  Unless otherwise specified, the menu descriptions below
  71. apply to the pick only.
  72.  
  73. (New for version 3.4)  The polynomial operations (such as PolyFact and
  74. PolyDiv) do not require you to specify the key.  If no key is specified,
  75. they will use the variable 'x' or the first variable found in the
  76. expression.  If the pick is an equation, the polynomial operations will
  77. automatically select one side or the other.
  78.  
  79. ----------------------------------------------------------------------------
  80. Menu Description:
  81.  
  82. Simplify [space] simplify expression.  It sorts it, combines common terms,
  83. calculates numbers, and rewrites it in canonical form.
  84.  
  85.   Note: Another similar function is SimpStep which is assigned to the 'x'.
  86.   The SimpStep function shows the intermediate steps of the simplification.
  87.  
  88. Distribute [d] distribute multiplication over add and subtract, and distribute
  89. exponents over multiplication and division.
  90.  
  91.   Note: Another similar function is DistChild which is assigned to the 'D'
  92.   (press shift and 'd').  The DistChild function is different in two ways.
  93.     1. DistChild does a top-down distribution.  For example,
  94.            (x*(a + b))^2  --->  (x^2)*(a + b)^2    using DistChild
  95.            (x*(a + b))^2  --->  (x*a + x*b)^2      using Distribute
  96.     2. DistChild does not distribute the top level factors in an expression
  97.        or equation.  You can use DistChild to simplify the result of a
  98.        factorization, like FactPoly or FactQuad.
  99.  
  100. Calculate [c] calculate all numbers.  e.g. 3*2 => 6.
  101.  
  102. PrimeFact [v] find the prime factorization of integers.  (This is limited by
  103. the ?d user option).
  104.  
  105. Integer [i] convert real numbers to integers if possible. e.g. 1.5 => 3/2
  106. This algorithm has two strategies.  First, it looks for repeating patterns
  107. in the fractional part of the number.  At least two repeating digits must
  108. be significant.  If that fails, it searches for an integer, d, such that d*x
  109. is an integer.  The user parameters ?e and ?d are used here.
  110.  
  111. Associate [a] rotates the elements of an associative group.
  112.  
  113. Comm-Deno [m] This is a TOGGLE to create a common denominator or to distribute
  114. division over add and subtract.
  115.  
  116. CharMode [8] toggle ascii 7-bit or 8-bit.  This is useful if you use
  117. print-screen.
  118.  
  119. Poly-Coef [p] collect the coefficients of a polynomial.  The pick must be a
  120. polynomial (not an equation) and the key must be the expression use as the
  121. base of the polynomial.
  122. e.g. pick is a*x + b*x + c, key is x ==> result is c + (a + b)*x
  123.  
  124. Center [home] horizontally center the formulas (this is default).
  125.  
  126. Poly-Div [\] polynomial division.  The pick must be a division (not an
  127. equation) and the numerator must be a polynomial with degree greater
  128. than or equal to the denominator.  The key must be the base variable.
  129. e.g. pick is (x^2 - y^2)/(x - y) and key is x. ==> result is x + y.
  130.  
  131. FactQuad [q] factor a 2nd degree polynomial using the quadratic equation.
  132. The pick must be a 2nd degree polynomial (not an equation)  The key must
  133. be the base variable.
  134. e.g. pick is (x^2 - y^2) and key is x. ==> result is (x + y)(x - y).
  135.  
  136. FactCubic [3] factor a 3rd degree polynomial using the cubic equation.
  137. The pick must be a 3rd degree polynomial (not an equation)  The key must
  138. be the base variable.  e.g. pick is (x^3 - y^3) and key is x. ==> result
  139. (after integer and several calculate and simplify) is
  140.          (x - y)*(x + (0.5 - 0.86i)*y)*(x + (0.5 + 0.86i)*y).
  141.  
  142.   Note:  This function isn't working very well.  Sometimes it gives the
  143.   wrong answer, and sometimes it uses up all memory.  The problem appears to
  144.   be with non-singular roots.  Only use it as a last resort.
  145.  
  146. FactPoly [f] factor a polynomial using rational roots.  The coefficients
  147. of the polynomial should not contains any non-integer numbers.  The pick
  148. must be a polynomial.  The key must be the base variable.  e.g.  pick
  149. is (x^4 - y^4) and key is x.  ==> result is (x - y)(x + y)(x - iy)(x + iy).
  150.  
  151.   Note:  If the polynomial has non-integer coefficients, sometimes
  152.   FactPoly will still work if you "fix" it using Calculate & Integer.
  153.   To force integer coefficients, put the terms of the polynomial over a
  154.   common denominator.  e.g. with x^2 - 0.5*x - 3 press Integer, Simplify,
  155.   CommDeno, to get (x^2*2 - x - 3*2)/2.  Now select the numerator (press
  156.   End) and then FactPoly.
  157.  
  158. Substitute [u] performs substitution using the key over the pick.  The key
  159. must be an equation.  e.g.  pick is a*x + b, key is x = y - 1 ==> result
  160. is a*(y - 1) + b.
  161.  
  162.   Notes: the LHS of key can be an expression, but you may need to change
  163.   the association on the pick in order for the substitute to work.  You
  164.   can use this with EqualKey: to replace the pick with the key, press =u.
  165.  
  166. ^N Expand [n] expand integer exponents.  e.g. x^3 ==> x*x*x
  167.  
  168. ExpJoin [j] join exponents of common base.  This is the opposite of
  169. distribute for exponents.
  170.  
  171. EqualKey [=] Change the key to an equation using the pick.  Neither pick
  172. nor key can be an equation prior to this operation.  e.g. pick is
  173. x + y, key is z ==> result key is x + y = z
  174.  
  175.   Note: you can use = and u to replace the pick with the key.
  176.  
  177. Add-key [+] add the key to the pick.  If pick is an equation then key is added
  178. to both sides.  If key is an equation then the corresponding sides are added
  179. to the pick.  If neither is an equation then the key is both added and
  180. subtracted.  e.g.  pick is x, key is y ==> result is x + y - y.
  181.  
  182. Sub-key [-] subtract the key from the pick.  See notes on add-key.
  183.  
  184. Mult-key [*] multiply the pick by the key.  See notes on add-key.
  185.  
  186. Div-key [/] divide the pick by the key.  See notes on add-key.
  187.  
  188. Exp-key [e] raise the pick to the key power.  See notes on add-key.
  189.  
  190. DeleteTop [del] delete the expression at the top of the screen.
  191.  
  192. EnterKey [k] prompt to type in a new key.  You must type the key and press
  193. F6 Enter when you are done.  (The F6 key should produce a ^Z, but if it
  194. doesn't work, then you can press ctrl-z.)  You can use either infix or
  195. postfix, depending on the ?f user option.
  196.  
  197.   Infix example z = (x^2 + y^2)^.5.
  198.  
  199.   Postfix example z x 2 ^ y 2 ^ + .5 ^ =.  You cannot use parentheses and
  200.   the tokens must be separated with blanks.
  201.  
  202.   Note:  You can use EnterKey to type anything that could appear in a data
  203.   file.  This includes visible comments (") and user options like ?m 41.
  204.   (Exception: you cannot change bgi drivers with ?g, but you can change the
  205.   mode or palette.  The ?f option does not take effect until end-of-file.)
  206.   Use the InsertKey command to add the new key to the expression list.
  207.  
  208. InsertKey [Ins] copies the key to the expression list.
  209.  
  210. EraseAll [Alt-e] delete all expressions from the work area (except the key).
  211.  
  212. DebugMode [Alt-d] dump the pick node tree for debugging purposes.
  213.  
  214. Load [l] load more expressions from a file.  Note: the previous expression
  215. list is not erased.
  216.  
  217. Save [s] save the expression list to a file.  The key is not saved.
  218.  
  219. Write [w] write the expression list in postfix notation.  This function is
  220. not very useful unless you like postfix.  I just left it in because it was
  221. in alged version 2.1.
  222.  
  223. EquRight ']' move the right operand from the left side of an equation to the
  224. right side.  e.g. pick is x + y = 3, result is x = 3 - y.
  225.  
  226. EquLeft '[' move the left operand from the left side of an equation to the
  227. right side.  e.g. pick is x + y = 3, result is y = x + 3.
  228.  
  229. Graph [g] switch to graphics mode and plot the function.  Press F1 for help
  230. text about graphics control keys.
  231.  
  232.   To use graphics you need a CGA, EGA, VGA, or Hercules video adapter, and you
  233.   need you have the corresponding bgi file (like EGAVGA.BGI) in the current
  234.   directory.  Alged can auto-detect these four modes.  If you have another bgi
  235.   file you want to use, then specify it with the ?g user option.
  236.  
  237. ------------------------------------------------------------------------------
  238. Comments On Other Things
  239.  
  240. If you enjoy Alged or have any suggestions, please send me an email.
  241. I do not want you to send me any money, but I like to get mail.
  242.  
  243. When you run alged from the command line you can specify one or more filenames
  244. for it to load.  Alged always tries to load the file ALGED.1ST first.  I
  245. suggest that you put the user option flags in this file, but you can put
  246. formulas there as well.  See alged.1st for a list of all the user options.
  247. Alged uses the current video mode, so before starting alged you can set it,
  248. for example, by typing MODE co80,43 (you may need ANSI.SYS for this command.)
  249.  
  250. The display algorithm used by alged is not perfect, for instance the following
  251. expression
  252.                1       2
  253.               ────    y
  254.                 2  + ────
  255.                x      b
  256.  
  257. the horizontal bars should be lined up.  You can make them line up by setting
  258. user option ?y to 0, but this causes other things to be ugly.
  259.  
  260. When you click on an expression with the mouse, it is mostly obvious.  The
  261. exception is exponentials.  To click on an exponential, point just above the
  262. top right corner of the base.  e.g. in
  263.                                             2
  264.                                      (x + y)
  265.  
  266. point just above the ')' and click.
  267.  
  268. You will notice at the top left of the menu are Simplify and Distribute.
  269. These operations are very useful for reducing a large complicated expression.
  270. After a PolyDiv, for instance, I usually hit Distribute and Simplify
  271. alternately until nothing changes.
  272.  
  273. This program does not support unary minus operator, thus to say -x, you must
  274. say -1*x.  It does not support roots, so to say sqrt(x) you must say x^0.5.
  275.  
  276. All numeric values are stored as IEEE 8-byte floats (double).  This allows
  277. the exponent to be -307 to +307 and the base has 16 significant digits.
  278. Alged only displays 15 digits, because the last one is sometimes garbage.
  279. This leads to a situation where sometimes numbers that look like integers
  280. really are not.  For instance, you might see 1*x and when you Simplify it
  281. doesn't change to x.  To fix this, press Integer, and the garbage digits are
  282. thrown out.  A word of caution:  if your problem uses very small numbers,
  283. like 1.23e-10, then you should not use Integer or else significant digits are
  284. removed.  The following special symbols are recognized...
  285.       pi = 3.14159265358979292
  286.       e =  2.71828182845904509
  287.  
  288. Alged allows any function with up to 5 arguments.  However, only the following
  289. functions are recognized in calculations and graphs.
  290.     With one argument: sin, cos, tan, acos, asin, atan, cosh, sinh,
  291.                        tanh, ln (base e), log (base 10), abs, rand, sign.
  292.     With two arguments: min, max, r, mod, atan2.
  293. The trigonometric functions are in radians.  The function r(x,y) uses the
  294. hypot function in C which is equal to (x^2 + y^2)^0.5 which is the hypotenuse.
  295. The atan2(y,x) is the angle (in radians, -pi to pi) of the line connecting
  296. (x,y) to the origin.
  297.  
  298. Variable names can be up to 24 characters.  However, function names can only
  299. be 7 characters.  This is because function parm pointers use part of the name
  300. memory.
  301.  
  302. The special variable "i" is recognized to be the square root of negative one.
  303. Thus, i*i is simplified to -1.  Also i^7.3 becomes -1*i^1.3.
  304. Imaginary numbers are supported in exponentials, (1+2i)^3 is evaluated to
  305. 2.24^3*(cos(1.11*3) + i*sin(1.11*3)) which is -11-2i.  I used the convention
  306. in which -pi<theta<=pi.  Imaginary numbers are not computed in functions
  307. like sin(3*i).
  308.  
  309. Both Simplify and Calculate will compute numerical results.  However, the
  310. difference is that Simplify will not attempt an operation on whole numbers
  311. that may produce a non-whole number.  For example, 4^0.5 is not reduced by
  312. Simplify, but it is by Calculate.
  313.  
  314. Some of the Poly operations will not work unless the expression is first
  315. completely distributed and simplified.
  316.  
  317. You should practice using Associate and PolyCoef.  These operations are
  318. useful for many things.  Associate will rearrange add/sub or mul/div or =,
  319. whichever is currently selected.
  320.  
  321. The FactrPoly operation can be very slow.  On a 486DX-33 to factor a 4th
  322. degree polynomial may take 15 seconds.  In general, I must admit that I made
  323. no effort at all to make Alged efficient.  It was already hard enough.
  324.  
  325. Customizing:
  326.  
  327. The Alged menu and other program text is stored in the ALGED.MNU file.  You
  328. can customize this file using a text editor.  You can change the size and
  329. layout of the menu, the hotkeys, or any of the text.  You can translate this
  330. file into another language (e.g. Italian).  If you do, send it to me so that
  331. I can distribute it!  When Alged starts, it loads ALGEDxyz.MNU from the
  332. current directory, where xyz is the language option specified with ?l.
  333. If ?l is not specified in ALGED.1ST or any of the data files, then the
  334. ALGED.MNU is loaded.
  335.  
  336. Final Notes:
  337.  
  338. One final note on reliability.  This program was thrown together as a hobby
  339. and it is not reliable.  You should check your answers by reversing the
  340. operation if possible.  You should save your work often.  When I developed
  341. this program, several times it hung the system.  I had to turn off the power
  342. of the PC.  So be careful, especially on very large operations like FactrPoly.
  343.  
  344. "This is what the Lord says: 'Let not the wise man boast of his wisdom or the
  345. strong man boast of his strength or the rich man boast of his riches, but let
  346. him who boasts boast about this: that he understands and know me, that I am
  347. the Lord, who exercises kindness, justice and righteousness on earth, for in
  348. these I delight,' declares the Lord."   Jeremiah 9.23-24
  349.  
  350.              End of help text.  Press any key to return.
  351.